package com.dzu.gulimall.auth.feign;

import com.dzu.common.utils.R;
import com.dzu.gulimall.auth.vo.SocialUser;
import com.dzu.gulimall.auth.vo.UserLoginVo;
import com.dzu.gulimall.auth.vo.UserRegistVo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * @author by ZhaoDong
 * @Classname MemberFeignService
 * @Description 用户远程服务
 * @Date 2021/6/25 21:14
 */
@FeignClient("gulimall-member")
public interface MemberFeignService {

    @PostMapping("/member/member/regist")
    R regist(@RequestBody UserRegistVo vo);

    @PostMapping("/member/member/login")
    R login(@RequestBody UserLoginVo vo);

    @RequestMapping("member/member/oauth2/login")
    R login(@RequestBody SocialUser socialUser);
}
